package xerr

import "github.com/zeromicro/x/errors"

func New(code int, msg string) error {
	return errors.New(code, msg)
}

func NewErr(msg string) error {
	return errors.New(ServerCommonError, msg)
}

func NewDBErr() error {
	return errors.New(DBError, ErrMsg(DBError))
}

func NewInternalServerErr() error {
	return errors.New(ServerCommonError, ErrMsg(ServerCommonError))
}
